Skip to content

Conversation

@MazterQyou
Copy link
Member

Check List

  • Tests have been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Description of Changes Made

This PR adds Limit-Sort to Projection push down rule which helps queries that could be planned as CubeScan but contain complex Projections that cannot be pushed down, and as such get planned using SQL push down.
It also fixes an issue with Limit-Sort combinations not being prioritized lower than SQL push down when Limit-Sort is not at the top of the plan.

Related test is included.

@MazterQyou MazterQyou requested a review from a team as a code owner July 14, 2025 19:05
@codecov
Copy link

codecov bot commented Jul 14, 2025

Codecov Report

Attention: Patch coverage is 98.77049% with 3 lines in your changes missing coverage. Please review.

Project coverage is 84.32%. Comparing base (f1d2735) to head (630290a).
Report is 9 commits behind head on master.

Files with missing lines Patch % Lines
...cubesql/cubesql/src/compile/rewrite/rules/order.rs 98.28% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #9776      +/-   ##
==========================================
+ Coverage   84.28%   84.32%   +0.04%     
==========================================
  Files         233      233              
  Lines       86704    86938     +234     
==========================================
+ Hits        73075    73309     +234     
  Misses      13629    13629              
Flag Coverage Δ
cubesql 84.32% <98.77%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@MazterQyou MazterQyou force-pushed the cubesql/push-down-limit-sort-projection branch from d16cd71 to 630290a Compare July 15, 2025 16:04
Copy link
Member

@KSDaemon KSDaemon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻 Cool!

@MazterQyou MazterQyou merged commit 72e6059 into master Jul 16, 2025
82 checks passed
@MazterQyou MazterQyou deleted the cubesql/push-down-limit-sort-projection branch July 16, 2025 18:14
Frank-TXS pushed a commit to Helge-TXS/cube that referenced this pull request Aug 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants